﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace PSE.ProcessManager.Server.InteligenceManagerInstance
{
    public class MultipleProcessKeyComparer : IEqualityComparer<MultipleProcessKey>
    {

        #region IEqualityComparer<MultipleProcessKey> Members

        public bool Equals(MultipleProcessKey x, MultipleProcessKey y)
        {
            return (x.ClientId == y.ClientId && x.ProcessId == y.ProcessId);
        }

        public int GetHashCode(MultipleProcessKey obj)
        {
            return obj.ClientId.GetHashCode() + obj.ProcessId.GetHashCode();
        }

        #endregion
    }

    public class MultipleProcessKey
    {
        public int ProcessId;
        public string ClientId;
    }
}
